import request from "@/utils/request";
// 限牌牌照费配置: 查询限牌牌照费列表
export function purchaseList(query) {
  return request({
    url: "/setting/restrictedPlateLicenseFee/pageList",
    method: "get",
    params: query,
  });
}
// 限牌牌照费配置: 新增
export function onAdd(data) {
  return request({
    url: "/setting/restrictedPlateLicenseFee/save",
    method: "post",
    data: data,
  });
}
// 限牌牌照费配置: 编辑
export function onEdit(data) {
  return request({
    url: "/setting/restrictedPlateLicenseFee/update",
    method: "post",
    data: data,
  });
}
// 限牌牌照费配置: 删除
export function onDelete(data) {
  return request({
    url: `/setting/restrictedPlateLicenseFee/delete/${data}`,
    method: "post",
  });
}
// 限牌牌照费配置: 获取实时的牌照费
export function onFee(data) {
  return request({
    url: `/setting/restrictedPlateLicenseFee/${data}`,
    method: "get",
  });
}

// 替换车定价: 查询
export function getCarList(query) {
  return request({
    url: `/setting/alternativeCarPricing/pageList`,
    method: "get",
    params: query,
  });
}

// 替换车定价: 新增
export function onCarSave(data) {
  return request({
    url: `/setting/alternativeCarPricing/save`,
    method: "post",
    data: data,
  });
}
// 替换车定价: 编辑
export function onCarUpdate(data) {
  return request({
    url: `/setting/alternativeCarPricing/update`,
    method: "post",
    data: data,
  });
}
// 替换车定价: 删除
export function onCarDelete(data) {
  return request({
    url: `/setting/alternativeCarPricing/delete/${data}`,
    method: "post",
  });
}
// 替换车定价: 查询
export function onCarSearch(query) {
  return request({
    url: `/setting/alternativeCarPricing/${query}`,
    method: "get",
  });
}

// 装饰: 查询列表数据
export function getDecorationList(query) {
  return request({
    url: `/setting/decorationFee/pageList`,
    method: "get",
    params: query,
  });
}
// 装饰: 新增
export function decorationAdd(data) {
  return request({
    url: `/setting/decorationFee/save`,
    method: "post",
    data: data,
  });
}
// 装饰: 编辑
export function decorationUpdate(data) {
  return request({
    url: `/setting/decorationFee/update`,
    method: "post",
    data: data,
  });
}
// 装饰: 删除
export function decorationDelete(data) {
  return request({
    url: `/setting/decorationFee/delete/${data}`,
    method: "post",
  });
}
// 装饰: 查询编辑
export function decorationEd(params) {
  return request({
    url: `/setting/decorationFee/${params}`,
    method: "get",
  });
}

// 上牌费用: 查询列表
export function getGpsList(query) {
  return request({
    url: `/setting/registrationFee/pageList`,
    method: "get",
    params: query,
  });
}
// 上牌费用: 新增
export function GpsAdd(data) {
  return request({
    url: `/setting/registrationFee/save`,
    method: "post",
    data: data,
  });
}

// 上牌费用: 编辑
export function GpsUpdate(data) {
  return request({
    url: `/setting/registrationFee/update`,
    method: "post",
    data: data,
  });
}
// 上牌费用: 删除
export function GpsDelete(data) {
  return request({
    url: `/setting/registrationFee/delete/${data}`,
    method: "post",
  });
}

// 上牌费用: 编辑获取数据
export function GpsDetail(query) {
  return request({
    url: `/setting/registrationFee/${query}`,
    method: "get",
  });
}

// 残值率: 获取数据列表
export function getRidList(query) {
  return request({
    url: `/setting/residualValueAdjustmentFactor/pageList`,
    method: "get",
    params: query,
  });
}
// 残值率: 新增
export function ridAdd(data) {
  return request({
    url: `/setting/residualValueAdjustmentFactor/save`,
    method: "post",
    data: data,
  });
}

// 残值率: 编辑
export function ridUpdate(data) {
  return request({
    url: `/setting/residualValueAdjustmentFactor/update`,
    method: "post",
    data: data,
  });
}
// 残值率: 删除
export function ridDelete(data) {
  return request({
    url: `/setting/residualValueAdjustmentFactor/delete/${data}`,
    method: "post",
  });
}
// 残值率: 获取编辑数据
export function ridDetail(query) {
  return request({
    url: `/setting/residualValueAdjustmentFactor/${query}`,
    method: "get",
  });
}

// 保险优惠系数: 列表数据
export function getInsuranceList(query) {
  return request({
    url: `/setting/insuranceDiscountFactor/pageList`,
    method: "get",
    params: query,
  });
}

// 保险优惠系数: 新增
export function insuranceAdd(data) {
  return request({
    url: `/setting/insuranceDiscountFactor/save`,
    method: "post",
    data: data,
  });
}

// 保险优惠系数: 编辑
export function insuranceUpdate(data) {
  return request({
    url: `/setting/insuranceDiscountFactor/update`,
    method: "post",
    data: data,
  });
}

// 保险优惠系数: 获取数据
export function insuranceFactor(data) {
  return request({
    url: `/setting/insuranceDiscountFactor/${data}`,
    method: "get",
  });
}

// 保险优惠系数: 删除
export function insuranceDelete(data) {
  return request({
    url: `/setting/insuranceDiscountFactor/delete/${data}`,
    method: "post",
  });
}

// 年检费配置: 获取列表数据
export function getYearFeeList(query) {
  return request({
    url: `/setting/annualInspectionFee/pageList`,
    method: "get",
    params: query,
  });
}

// 年检费配置: 新增
export function yearFeeAdd(data) {
  return request({
    url: `/setting/annualInspectionFee/save`,
    method: "post",
    data: data,
  });
}

// 年检费配置: 删除
export function yearFeeDelete(data) {
  return request({
    url: `/setting/annualInspectionFee/delete/${data}`,
    method: "post",
  });
}

// 年检费配置: 编辑获取数据单个
export function yearFeeLion(data) {
  return request({
    url: `/setting/annualInspectionFee/${data}`,
    method: "get",
  });
}

// 年检费配置: 更新
export function yearFeeUpdate(data) {
  return request({
    url: `/setting/annualInspectionFee/update`,
    method: "post",
    data: data,
  });
}

// 维保套餐: 获取列表
export function getPackageList(query) {
  return request({
    url: `/setting/maintenancePackage/pageList`,
    method: "get",
    params: query,
  });
}
// 维保套餐: 新增
export function packageAdd(data) {
  return request({
    url: `/setting/maintenancePackage/save`,
    method: "post",
    data: data,
  });
}

// 维保套餐: 删除
export function packageDelete(data) {
  return request({
    url: `/setting/maintenancePackage/delete/${data}`,
    method: "post",
  });
}

// 维保套餐: 编辑前获取
export function GetPackageEdit(data) {
  return request({
    url: `/setting/maintenancePackage/${data}`,
    method: "get",
  });
}

// 维保套餐: 修改
export function PackageUpdate(data) {
  return request({
    url: `/setting/maintenancePackage/update`,
    method: "post",
    data: data,
  });
}

// 标准里程残值率: 获取列表数据
export function getSalvageList(query) {
  return request({
    url: `/setting/carSeriesResidualValueRate/pageList`,
    method: "get",
    params: query,
  });
}

// 标准里程残值率: 新增
export function salvageAdd(data) {
  return request({
    url: `/setting/carSeriesResidualValueRate/save`,
    method: "post",
    data: data,
  });
}
// 标准里程残值率: 编辑
export function salvageUpdate(data) {
  return request({
    url: `/setting/carSeriesResidualValueRate/update`,
    method: "post",
    data: data,
  });
}
// 标准里程残值率: 删除
export function salvageDelete(data) {
  return request({
    url: `/setting/carSeriesResidualValueRate/delete/${data}`,
    method: "post",
  });
}

// 标准里程残值率: 编辑前获取详情
export function salvageGet(query) {
  return request({
    url: `/setting/carSeriesResidualValueRate/${query}`,
    method: "get",
  });
}

// 维保费分项明细: 获取列表数据
export function getCarModelList(query) {
  return request({
    url: `/setting/carModelMaintenanceFeeBase/pageList`,
    method: "get",
    params: query,
  });
}

// 维保费分项明细: 新增
export function carModelAdd(data) {
  return request({
    url: `/setting/carModelMaintenanceFeeBase/save`,
    method: "post",
    data: data,
  });
}

// 维保费分项明细: 删除
export function carModelDelete(data) {
  return request({
    url: `/setting/carModelMaintenanceFeeBase/delete/${data}`,
    method: "post",
  });
}

// 维保费分项明细: 编辑前获取详情
export function carModelDetail(query) {
  return request({
    url: `/setting/carModelMaintenanceFeeBase/${query}`,
    method: "get",
  });
}
// 维保费分项明细：编辑
export function carModelUpdate(data) {
  return request({
    url: `/setting/carModelMaintenanceFeeBase/update`,
    method: "post",
    data: data,
  });
}
// 维保费分项明细：弹窗
export function getListDig(query) {
  return request({
    url: `/car/carModel/getModelList`,
    method: "get",
    params: query,
  });
}

// 维保费分项明细：获取列表数据
export function getMaintenanceShopList(query) {
  return request({
    url: `/setting/supplierMaintenanceFeeBase/pageList`,
    method: "get",
    params: query,
  });
}

// 维保费分项明细：新增
export function maintenanceShopAdd(data) {
  return request({
    url: `/setting/supplierMaintenanceFeeBase/save`,
    method: "post",
    data: data,
  });
}
// 维保费分项明细：删除
export function maintenanceDelete(data) {
  return request({
    url: `/setting/supplierMaintenanceFeeBase/delete/${data}`,
    method: "post",
  });
}
// 维保费分项明细：编辑前获取详情
export function maintenanceDetail(query) {
  return request({
    url: `/setting/supplierMaintenanceFeeBase/${query}`,
    method: "get",
  });
}

// 维保费分项明细：编辑
export function maintenanceUpdate(data) {
  return request({
    url: `/setting/supplierMaintenanceFeeBase/update`,
    method: "post",
    data: data,
  });
}

// 贷款测算配置： 获取列表数据
export function getLoanList(query) {
  return request({
    url: `/setting/loanEstimationConfigItem/pageList`,
    method: "get",
    params: query,
  });
}

// 贷款测算配置： 新增
export function loanAdd(data) {
  return request({
    url: `/setting/loanEstimationConfigItem/save`,
    method: "post",
    data: data,
  });
}
// 贷款测算配置： 删除
export function loanDelete(data) {
  return request({
    url: `/setting/loanEstimationConfigItem/delete/${data}`,
    method: "post",
  });
}

// 贷款测算配置： 编辑前获取详情
export function loanDetail(query) {
  return request({
    url: `/setting/loanEstimationConfigItem/${query}`,
    method: "get",
  });
}

// 贷款测算配置： 编辑
export function loanUpdate(data) {
  return request({
    url: `/setting/loanEstimationConfigItem/update`,
    method: "post",
    data: data,
  });
}

// 维保公里数配置： 获取列表数据
export function getMainList(query) {
  return request({
    url: `/setting/maintenanceMileageBase/pageList`,
    method: "get",
    params: query,
  });
}

// 维保公里数配置： 新增
export function mainAdd(data) {
  return request({
    url: `/setting/maintenanceMileageBase/save`,
    method: "post",
    data: data,
  });
}

// 维保公里数配置： 删除
export function mainDelete(data) {
  return request({
    url: `/setting/maintenanceMileageBase/delete/${data}`,
    method: "post",
  });
}

// 维保公里数配置： 编辑
export function mainUpdate(data) {
  return request({
    url: `/setting/maintenanceMileageBase/update`,
    method: "post",
    data: data,
  });
}

// 维保公里数配置： 编辑前获取详情
export function mainDetail(query) {
  return request({
    url: `/setting/maintenanceMileageBase/${query}`,
    method: "get",
  });
}

// 替代车级别： 获取列表数据
export function getReplaceCarList(query) {
  return request({
    url: `/setting/alternativeCarLevel/pageList`,
    method: "get",
    params: query,
  });
}

// 替代车级别： 新增
export function replaceCarAdd(data) {
  return request({
    url: `/setting/alternativeCarLevel/save`,
    method: "post",
    data: data,
  });
}

// 替代车级别： 删除
export function replaceCarDelete(data) {
  return request({
    url: `/setting/alternativeCarLevel/delete/${data}`,
    method: "post",
  });
}

// 替代车级别： 编辑前获取详情
export function replaceCarDetail(query) {
  return request({
    url: `/setting/alternativeCarLevel/${query}`,
    method: "get",
  });
}

// 替代车级别： 编辑
export function replaceCarUpdate(data) {
  return request({
    url: `/setting/alternativeCarLevel/update`,
    method: "post",
    data: data,
  });
}

// 替代车级别： 下拉级别选择
export function getCarLevelList() {
  return request({
    url: `/setting/alternativeCarLevel/list`,
    method: "get",
  });
}

// 保险： 获取数据列表
export function getFeeBaseList(query) {
  return request({
    url: `/setting/insuranceItemFeeBase/pageList`,
    method: "get",
    params: query,
  });
}

// 保险： 新增
export function feeBaseAdd(data) {
  return request({
    url: `/setting/insuranceItemFeeBase/save`,
    method: "post",
    data: data,
  });
}

// 保险： 删除
export function feeBaseDelete(data) {
  return request({
    url: `/setting/insuranceItemFeeBase/delete/${data}`,
    method: "post",
  });
}

// 保险： 删除
export function feeBaseUpdate(data) {
  return request({
    url: `/setting/insuranceItemFeeBase/update`,
    method: "post",
    data: data,
  });
}
// 保险： 编辑前获取详情
export function feeBaseDetail(query) {
  return request({
    url: `/setting/insuranceItemFeeBase/${query}`,
    method: "get",
  });
}
// 品牌
export function getBrandName(data) {
  return request({
    url: `/car/carBrand/getBrandNameByIds`,
    method: "post",
    data: data,
  });
}
// 车系
export function getSeriesName(data) {
  return request({
    url: `/car/carSeries/getSeriesNameByIds`,
    method: "post",
    data: data,
  });
}

// 车型
export function getModelName(data) {
  return request({
    url: `/car/carModel/getModelNameByIds`,
    method: "post",
    data: data,
  });
}

// 车型搜索
export function getModelNameSearch(data) {
  return request({
    url: `/car/carModel/getModelNameByIds`,
    method: "post",
    data: data,
  });
}

// 获取产品列表
export function getProductList(query) {
  return request({
    url: `/quoter/scheme/pageList`,
    method: "get",
    params: query,
  });
}
// 修改上下架状态
export function updateShelveStatus(data) {
  return request({
    url: `/quoter/scheme/updateShelveStatus`,
    method: "post",
    data: data,
  });
}

// 获取供应商列表
export function getInsuranceSelectList(params) {
  return request({
    url: "/supplier/supplier/allList",
    method: "get",
    params: params,
  });
}

// 新增报价产品方案
export function save(data) {
  return request({
    url: `/quoter/scheme/save`,
    method: "post",
    data: data,
  });
}

// 获取报价产品方案详情
export function getDetailProduct(id) {
  return request({
    url: `/quoter/scheme/${id}`,
    method: "get",
  });
}
// 获取报价产品方案详情
export function updateProduct(data) {
  return request({
    url: `/quoter/scheme/update`,
    method: "post",
    data: data,
  });
}


// 查看车型分页列表
export function getQueryModelByIdList(params) {
  return request({
    url: `/car/carModel/queryCarModelTypePageByIdList`,
    method: "get",
    params: params,
  });
}
// 新增车型
export function updateCarModel(data) {
  return request({
    url: `/quoter/scheme/carModel/update`,
    method: "post",
    data: data,
  });
}

// 产品方案分页查询
export function getModelCar(data) {
  return request({
    url: `/quoter/scheme/carModel/pageQuery`,
    method: "post",
    data: data,
  });
}

// 删除车型
export function deleteCar(data) {
  return request({
    url: `/quoter/scheme/carModel/delete`,
    method: "post",
    data: data,
  });
}

// 定价档次
export function getCommonList(params) {
  return request({
    url: `/quoter/pricing-irr-grade/list`,
    method: "get",
    params: params,
  });
}


// 查询客户类型列表
export function getCustomerTypeList(params) {
  return request({
    url: `/quoter/customerType/list`,
    method: "get",
    params: params,
  });
}

// 新增报价客户类型
export function addCustomerType(data) {
  return request({
    url: `/quoter/customerType/save`,
    method: "post",
    data: data,
  });
}

// 删除报价客户类型
export function deleteCustomerType(ids) {
  return request({
    url: `/quoter/customerType/delete/${ids}`,
    method: "post",

  });
}

// 查询税率配置列表
export function getTaxRateList(params) {
  return request({
    url: `/setting/taxRate/pageList`,
    method: "get",
    params: params
  });
}

// 新增税率配置
export function saveTaxRateList(data) {
  return request({
    url: `/setting/taxRate/save`,
    method: "post",
    data: data
  });
}

// 删除税率配置
export function deleteTaxRateList(data) {
  return request({
    url: `/setting/taxRate/delete/${data}`,
    method: "post",
  });
}


//获取税率配置
export function viewTaxRateList(params) {
  return request({
    url: `/setting/taxRate/${params}`,
    method: "get",
  });
}

//修改税率配置
export function updateTaxRateList(data) {
  return request({
    url: `/setting/taxRate/update`,
    method: "post",
    data: data
  });
}


//限牌牌照费 修改启用状态
export function updateEnable(data) {
  return request({
    url: `/setting/restrictedPlateLicenseFee/update-enable-status`,
    method: "post",
    data: data
  });
}
//上牌费用 修改启用状态
export function updateEnableFee(data) {
  return request({
    url: `/setting/registrationFee/update-enable-status`,
    method: "post",
    data: data
  });
}

//替代车定价费用 修改启用状态
export function updateEnableCarPricing(data) {
  return request({
    url: `/setting/alternativeCarPricing/update-enable-status`,
    method: "post",
    data: data
  });
}

//替代车级别费用 修改启用状态
export function updateEnableCarLevel(data) {
  return request({
    url: `/setting/alternativeCarLevel/update-enable-status`,
    method: "post",
    data: data
  });
}

// 残值率导入
export const COEFFICIENTiMPORT =
  "/setting/residualValueAdjustmentFactor/import";

// 标准里程残值率
export const STANDARDMILEAGE =
  "/setting/carSeriesResidualValueRate/import";


//  维保费分项明细
export const MAINTENANCEFE =
  "/setting/carModelMaintenanceFeeBase/import";

//   4s店与维修厂维保 
export const SUPPLIER =
  "/setting/supplierMaintenanceFeeBase/import";

// 模板下载
export function TEMPLATEDRIVER(templateCode) {
  return `/system/templateFile/download/${templateCode}`
}
// 下拉查询
export function getConditions() {
  return request({
    url: `/quoter/scheme/query-conditions`,
    method: "get",
  })
}

// 产品方案关联车型新增
export function addCarModel(data) {
  return request({
    url: `/quoter/scheme/carModel/add`,
    method: "post",
    data: data,
  })
}


// 根据产品方案查询编辑筛选条件
export function querySelectModelId(query) {
  return request({
    url: `/quoter/scheme/carModel/querySelectModelId`,
    method: "get",
    params: query,
  })
}


